using System;
using System.Collections.Generic;
using System.Text;
using System.Data.SqlClient;
namespace SRW.SetInfo
{
   class SetWtlink
   {
      public static SqlCommand Set_Wtlink_Data(SqlCommand cmd, Wtlink mWtlink,bool CheckPk)
      {
         
         if (!(string.IsNullOrEmpty(mWtlink.pkID.ToString())))
         {
            if (CheckPk)
               cmd.Parameters.AddWithValue("@pkID", mWtlink.pkID);
         }
         if (!(string.IsNullOrEmpty(mWtlink.linkname.ToString())))
         {
         cmd.Parameters.AddWithValue("@linkname", mWtlink.linkname);
         }
         if (!(string.IsNullOrEmpty(mWtlink.linkplace.ToString())))
         {
         cmd.Parameters.AddWithValue("@linkplace", mWtlink.linkplace);
         }
         return cmd;
      }
   }
}
